<!--^^^^^^^^^^^^^^^^^^^^^^^^^^相册^^^^^^^^^^^^^^^^^^^^^^^^^^^-->
<div class="content">
  <div class="topmargin">
    <div class="title">最新相册</div>
    <%= link_to "查看更多",
      document_url(:id => :albums, :cmd => :albums_index),
      :target => :_blank
  %>
  </div>
  <div class="album_minute">
    <% Album.up_to_date_albums.each do |album| %>
      <% if album.photos.length != 0 %>
        <div class="centerImg">
          <% link_to(album_url(album), :target => :_blank)  do  %>
            <%= photo_image_tag album.new_photo_of_the_album, :height => 105 %>
          <% end %>
        </div>
      <% end %>
    <% end %>
  </div>
</div>
<!--^^^^^^^^^^^^^^^^^^^^^^^^^^日志^^^^^^^^^^^^^^^^^^^^^^^^^^^-->
<div class="content">
  <div class="topmargin">
    <div class="title">最新日志</div>
    <%= link_to "查看更多",
      document_url(:id => :logs, :cmd => :logs_index),
      :target => :_blank
  %>
  </div>
  <% Article.up_to_date_articles.each do |article| %>
    <div class="monomer">
      <div id="picture"><%= valleyer_logo_image_tag article.author, {:width => 60, :height => 60} %></div>
      <div class="minute">
        <div class="topic">
          <div class="auther">
            <%= link_to truncate(article.author.nick_name, :length => 5),
              valleyer_url(article.author),
              :target => :_blank,
              :class => "client_name",
              :title => article.author.nick_name
          %>
          </div>
          <p>发表日志</p>
          <%= link_to truncate(article.title, :length => 10),
            show_log_url(article),
            :title => article.title,
            :target => :_blanck
        %>
          <div class="time"><%= article.created_at.strftime("%Y-%m-%d %H:%M") %></div>
        </div>
        <div class="summarize">
          <%= truncate("#{strip_tags(article.content)}", :length => 100) %>
        </div>
        <div class="writer">
          <!--<div class="photo"><a href="javascript:;"><%= image_tag('valleyer/logEx.jpg') %></a></div>-->
          <div class="read">
            阅读：(<%= article.browse_records_count %>)&nbsp;&nbsp;
            评论：(<%= article.post_sessions.length %>)
          </div>
        </div>
      </div>
    </div>
  <% end %>
</div>
<!--^^^^^^^^^^^^^^^^^^^^^^^^^^转载^^^^^^^^^^^^^^^^^^^^^^^^^^^-->
<div class="content">
  <div class="topmargin">
    <div class="title">最新转载</div>
    <%= link_to "查看更多",
      document_url(:id => :reships, :cmd => :reships_index),
      :target => :_blank
  %>
  </div>
  <% Reship.up_to_date_reships.each do |reship| %>
    <div class="monomer">
      <div id="picture">
        <%= valleyer_logo_image_tag reship.author, {:width => 60, :height => 60} %>
      </div>
      <div class="minute">
        <div class="topic">
          <div class="auther">
            <%= link_to truncate(reship.author.nick_name, :length => 5),
              valleyer_url(reship.author),
              :target => :_blank,
              :class => "client_name",
              :title => reship.author.nick_name
          %>
          </div>
          <p>转载日志</p>
          <%= link_to truncate(reship.title, :length => 10),
            show_reship_url(reship),
            :title => reship.title,
            :target => :_blanck
        %>
          <div class="time"><%= reship.created_at.strftime("%Y-%m-%d %H:%M") %></div>
        </div>
        <div class="summarize"><%= truncate("#{strip_tags(reship.content)}", :length => 100) %></div>
        <div class="writer">
          <div class="read">
            阅读：(<%= reship.browse_records_count %>)&nbsp;&nbsp;
            评论：(<%= reship.post_sessions.length %>)
          </div>
        </div>
      </div>
    </div>
  <% end %>
</div>
